/**
 * Generate time : 2011-06-08 17:01:53
 * Version : 1.0.1.V20070717
 */
package com.baosight.sczx.zm.cl.domain;

import com.baosight.iplat4j.util.NumberUtils;
import com.baosight.iplat4j.core.ei.EiColumn;
import com.baosight.iplat4j.ep.DaoEPBase;
import java.util.HashMap;
import java.util.Map;
import com.baosight.iplat4j.util.StringUtils;

/**
 * ZMCLSecurityPath
 * 
 */
public class ZMCLSecurityPath extends DaoEPBase {

	private String fdKeyId = " "; /* 主键 */
	private String fdPathCode = " "; /* 路线编号 */
	private String fdPathName = " "; /* 路线名称 */
	private Long fdFrequency = new Long(0); /* 检查频率 */
	private String fdFrequencyUnits = " "; /* 检查频率单位 */
	private String fdStatus = " "; /* 路线状态 */
	private String fdRemark = " "; /* 备注 */
	private String fdNoteCode = " "; /* 巡检工单编号 */

	/**
	 * initialize the metadata
	 */
	public void initMetaData() {
		EiColumn eiColumn;

		eiColumn = new EiColumn("fdKeyId");
		eiColumn.setPrimaryKey(true);
		eiColumn.setFieldLength(32);
		eiColumn.setDescName("主键");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdPathCode");
		eiColumn.setFieldLength(20);
		eiColumn.setDescName("路线编号");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdPathName");
		eiColumn.setFieldLength(50);
		eiColumn.setDescName("路线名称");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdFrequency");
		eiColumn.setType("N");
		eiColumn.setScaleLength(0);
		eiColumn.setFieldLength(38);
		eiColumn.setDescName("检查频率");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdFrequencyUnits");
		eiColumn.setFieldLength(5);
		eiColumn.setDescName("检查频率单位");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdStatus");
		eiColumn.setFieldLength(10);
		eiColumn.setDescName("路线状态");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdRemark");
		eiColumn.setFieldLength(500);
		eiColumn.setDescName("备注");
		eiMetadata.addMeta(eiColumn);

		eiColumn = new EiColumn("fdNoteCode");
		eiColumn.setFieldLength(20);
		eiColumn.setDescName("巡检工单编号");
		eiMetadata.addMeta(eiColumn);

	}

	/**
	 * the constructor
	 */
	public ZMCLSecurityPath() {
		initMetaData();
	}

	/**
	 * get the fdKeyId - 主键
	 * 
	 * @return the fdKeyId
	 */
	public String getFdKeyId() {
		return this.fdKeyId;
	}

	/**
	 * set the fdKeyId - 主键
	 */
	public void setFdKeyId(String fdKeyId) {
		this.fdKeyId = fdKeyId;
	}

	/**
	 * get the fdPathCode - 路线编号
	 * 
	 * @return the fdPathCode
	 */
	public String getFdPathCode() {
		return this.fdPathCode;
	}

	/**
	 * set the fdPathCode - 路线编号
	 */
	public void setFdPathCode(String fdPathCode) {
		this.fdPathCode = fdPathCode;
	}

	/**
	 * get the fdPathName - 路线名称
	 * 
	 * @return the fdPathName
	 */
	public String getFdPathName() {
		return this.fdPathName;
	}

	/**
	 * set the fdPathName - 路线名称
	 */
	public void setFdPathName(String fdPathName) {
		this.fdPathName = fdPathName;
	}

	/**
	 * get the fdFrequency - 检查频率
	 * 
	 * @return the fdFrequency
	 */
	public Long getFdFrequency() {
		return this.fdFrequency;
	}

	/**
	 * set the fdFrequency - 检查频率
	 */
	public void setFdFrequency(Long fdFrequency) {
		this.fdFrequency = fdFrequency;
	}

	/**
	 * get the fdFrequencyUnits - 检查频率单位
	 * 
	 * @return the fdFrequencyUnits
	 */
	public String getFdFrequencyUnits() {
		return this.fdFrequencyUnits;
	}

	/**
	 * set the fdFrequencyUnits - 检查频率单位
	 */
	public void setFdFrequencyUnits(String fdFrequencyUnits) {
		this.fdFrequencyUnits = fdFrequencyUnits;
	}

	/**
	 * get the fdStatus - 路线状态
	 * 
	 * @return the fdStatus
	 */
	public String getFdStatus() {
		return this.fdStatus;
	}

	/**
	 * set the fdStatus - 路线状态
	 */
	public void setFdStatus(String fdStatus) {
		this.fdStatus = fdStatus;
	}

	/**
	 * get the fdRemark - 备注
	 * 
	 * @return the fdRemark
	 */
	public String getFdRemark() {
		return this.fdRemark;
	}

	/**
	 * set the fdRemark - 备注
	 */
	public void setFdRemark(String fdRemark) {
		this.fdRemark = fdRemark;
	}

	/**
	 * get the fdNoteCode - 巡检工单编号
	 * 
	 * @return the fdNoteCode
	 */
	public String getFdNoteCode() {
		return this.fdNoteCode;
	}

	/**
	 * set the fdNoteCode - 巡检工单编号
	 */
	public void setFdNoteCode(String fdNoteCode) {
		this.fdNoteCode = fdNoteCode;
	}

	/**
	 * get the value from Map
	 */
	@SuppressWarnings("rawtypes")
	public void fromMap(Map map) {

		setFdKeyId(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdKeyId")), fdKeyId));
		setFdPathCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdPathCode")), fdPathCode));
		setFdPathName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdPathName")), fdPathName));
		setFdFrequency(NumberUtils.toLong(StringUtils.toString(map.get("fdFrequency")), fdFrequency));
		setFdFrequencyUnits(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdFrequencyUnits")), fdFrequencyUnits));
		setFdStatus(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdStatus")), fdStatus));
		setFdRemark(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdRemark")), fdRemark));
		setFdNoteCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdNoteCode")), fdNoteCode));
	}

	/**
	 * set the value to Map
	 */
	@SuppressWarnings({ "rawtypes", "unchecked" })
	public Map toMap() {

		Map map = new HashMap();
		map.put("fdKeyId", StringUtils.toString(fdKeyId, eiMetadata.getMeta("fdKeyId")));
		map.put("fdPathCode", StringUtils.toString(fdPathCode, eiMetadata.getMeta("fdPathCode")));
		map.put("fdPathName", StringUtils.toString(fdPathName, eiMetadata.getMeta("fdPathName")));
		map.put("fdFrequency", StringUtils.toString(fdFrequency, eiMetadata.getMeta("fdFrequency")));
		map.put("fdFrequencyUnits", StringUtils.toString(fdFrequencyUnits, eiMetadata.getMeta("fdFrequencyUnits")));
		map.put("fdStatus", StringUtils.toString(fdStatus, eiMetadata.getMeta("fdStatus")));
		map.put("fdRemark", StringUtils.toString(fdRemark, eiMetadata.getMeta("fdRemark")));
		map.put("fdNoteCode", StringUtils.toString(fdNoteCode, eiMetadata.getMeta("fdNoteCode")));

		return map;

	}
}